#include "glare.core.PlatformWindow.h"

#if GLARE_PLATFORM == GLARE_PLATFORM_WIN32
#	include "glare.core.Win32Window.h"
#elif GLARE_PLATFORM == GLARE_PLATFORM_ANDROID
#	include "glare.core.AndroidWindow.h"
#endif

namespace Glare {

	PlatformWindow::PlatformWindow(const uint& width, const uint& height)
		: _width(width)
		, _height(height)
	{

	}

	PlatformWindow::~PlatformWindow()
	{

	}

	/** Creates the default PlatformWindow implementation for the current platform */
	PlatformWindow* PlatformWindow::CreateDefaultWindow(const uint& width, const uint& height, ConstructionParams* params)
	{
#if GLARE_PLATFORM == GLARE_PLATFORM_WIN32
		return new Win32Window(width, height, params);

#elif GLARE_PLATFORM == GLARE_PLATFORM_ANDROID
		return new AndroidWindow(width, height, params);

#else
		throw Exception("Unable to create a platform window for the current platform");
#endif
	}

	const uint& PlatformWindow::GetWidth() const
	{
		return _width;
	}
	const uint& PlatformWindow::GetHeight() const
	{
		return _height;
	}
}
